#include<bits/stdc++.h>
using namespace std;
int main()
{
	int n,a[100][100],t=-100,ti,tj,i,j;
	cin>>n;
	for(i=1;i<=n;i++)
	for(j=1;j<=n;j++)
	{
		cin>>a[i][j];
		a[i][j]=abs(a[i][j]);
		if(t<a[i][j])
		t=a[i][j],ti=i,tj=j;
	}
	cout<<t<<" "<<i-1<<" "<<j-1;
    return 0;
}
